<div class="uk-layui-form">
    <form class="layui-form uk-form" action="/admin/callcenter/skill/save.html" data-toggle="ajax-form" data-inner="#callCenterContent">
    	<input type="hidden" name="hostid" value="${pbxHost.id!''}">
        <div class="layui-collapse">
			<div class="layui-colla-item">
				<h2 class="layui-colla-title">基本信息<font color="red">（带*表示必填项）</font></h2>
				<div class="layui-colla-content layui-show">
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">技能组名称：</label>
				            <div class="layui-input-inline">
				                <input type="text" name="name" required lay-verify="required" placeholder="请输入技能组名称" autocomplete="off" class="layui-input">
				            </div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">代码：</label>
				            <div class="layui-input-inline">
				                <input type="text" name="skill" required lay-verify="required" placeholder="请输入技能组代码" autocomplete="off" class="layui-input">
				            </div>
						</div>
			        </div>
					<div class="layui-form-item">
			            <label class="layui-form-label">绑定SIP网关：</label>
			            <div class="layui-input-inline">
			            	<select id="siptrunk1" name="siptrunk">
								<option value="">请选择...</option>
								<#if sipTrunkListList??>
								<#list sipTrunkListList as sipTrunkInfo>
								<option value="${sipTrunkInfo.id!''}">${sipTrunkInfo.name!''}</option>
								</#list>
								</#if>
							</select>    
			            </div>
			        </div>
				</div>
			</div>
			<div class="layui-colla-item">
				<h2 class="layui-colla-title">队列参数</h2>
				<div class="layui-colla-content layui-show">
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">策略模式<a id="scheme_1" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('策略模式，定义来电根据哪些策略模式查找队列中的客户端', '#scheme_1',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：
							</label>
							<div class="layui-input-inline">
								<select name="strategy" >
									<option value="ring-all">同时呼叫所有的客户端，某个接听后其它客户端自动挂断</option>
									<option value="longest-idle-agent">最大空闲客户端优先</option>
									<option value="round-robin">最后一次客户端通话的优先</option>
									<option value="top-down">从上倒下查找客户端</option>
									<option value="agent-with-least-talk-time">最少通话时间的客户端优先</option>
									<option value="agent-with-fewest-calls">最少通话次数的客户端优先</option>
									<option value="sequentially-by-agent-order">按照规则和等级依次查找客户端</option>
								</select>
							</div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">
							语音文件参数
							<a id="scheme_2" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('语音文件参数', '#scheme_2',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：
							</label>
							<div class="layui-input-inline">
				                <input type="text" name="mohsound" placeholder="请输入语音文件参数" value="${r'$${hold_music}'}" autocomplete="off" class="layui-input">
				            </div>
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">
							播报语音
							<a id="scheme_3" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('播报语音', '#scheme_3',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：
							</label>
							<div class="layui-input-inline">
								<select name="announcesound" >
									<option value="" >请选择</option>
									<#if mediaList?? && mediaList?size gt 0>
									<#list mediaList as media>
									<option value="${media.filename!''}">${media.name!''}</option>
									</#list>
									</#if>
								</select>
							</div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">播报频率<a id="scheme_4" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('播报频率，单位：秒', '#scheme_4',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
				                <input type="number" min="0" name="announcefrequency" placeholder="播报频率" value="40" autocomplete="off" class="layui-input">
				            </div>
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">
							录音文件参数
							<a id="scheme_5" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('语音文件参数', '#scheme_5',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：
							</label>
							<div class="layui-input-inline">
				                <input type="text" name="recordtemplate" placeholder="录音文件参数" value="${r'$${base_dir}/recordings/archive/${strftime(%Y-%m-%d-%H-%M-%S)}_${destination_number}_${caller_id_number}.wav'}" autocomplete="off" class="layui-input">
				            </div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">时基分数<a id="scheme_6" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('Queue：默认为队列,如果设置为队列,任何来电的基础评分在进入队列之前不会被增加（无论他们的呼叫的总长度）。<br>System：如果设置为系统，这将增加原来已经通话过(或进入系统)的来电电话基础评分。提高来电评分让在队列中等待时间较长的得到接听.只要在系统中的来电优先于其它队列中的来电。', '#scheme_6',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：
							</label>
							<div class="layui-input-inline">
								<select name="timebasescore" >
									<option value="queue">Queue</option>
									<option value="system">System</option>
								</select>
							</div>
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">最大等待时间<a id="scheme_7" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('最大等待时间，0默认禁用。任何来电如果超过设置的最大等待时间将退出callcenter排队。如果有来电已经分配了客户端，但是等待超时后可以进入语音信箱。单位：分钟', '#scheme_7',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
				                <input type="number" min="0" name="maxwaittime" placeholder="最大等待时间" value="0" autocomplete="off" class="layui-input">
				            </div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">最大等待时间与无代理<a id="scheme_8" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('最大等待时间与无代理。默认为0被禁用。 在设定的时间内如果没有分配客户端的话，允许主叫离开排队。这个设置将保护所有进入队列后来电，避免客户端发意外注销后来电一直等待。单位：分钟', '#scheme_8',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
				                <input type="number" min="0" name="maxwtnoagent" placeholder="最大等待时间与无代理" value="0" autocomplete="off" class="layui-input">
				            </div>
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">拒绝新来电间隔时间<a id="scheme_9" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('默认是5分钟，在超过Max-wait-time-with-no-agent时间后，在本参数定义的时间内拒绝新的来电。这是考虑到没有客户端登录超过5分钟，但是新来电达到五分钟后下限后可以。单位：分钟', '#scheme_9',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
				                <input type="number" min="0" name="maxwtnareached" placeholder="最大等待时间与无代理" value="5" autocomplete="off" class="layui-input">
				            </div>
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">等级规则应用<a id="scheme_10" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('True: 使等级规则设置的参数生效<br> Flase: 设置的等级规则无效', '#scheme_10',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
								<select name="trapply" >
									<option value="false">False</option>
									<option value="true">True</option>
								</select>
							</div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">等级规则设置的时间<a id="scheme_11" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('主叫需要等待设定时间后,才能根据等级规则查找客户端。单位：秒', '#scheme_11',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
				                <input type="number" min="0" name="trwaitsecond" placeholder="等级规则设置的时间" value="300" autocomplete="off" class="layui-input">
				            </div>
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">等级规则级别<a id="scheme_12" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('False：超过Tier-rule-wait-second设置的时间后，为来电按顺序提供所有的等级规则服务。<br>True：来电必须等待Tier-rule-wait-second值乘以tier中的level值时间后，为来电按顺序提供所有的等级规则服务。', '#scheme_12',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
								<select name="trmultiplylevel" >
									<option value="true">True</option>
									<option value="false">False</option>
								</select>
							</div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">是否跳过等级规则<a id="scheme_13" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('True: 设置true，来电将跳过等级规则直接查找空闲的客户端.<br>False:设置false，根据等级规则查找客户端. ', '#scheme_13',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
								<select name="trnoagentnowait" >
									<option value="false">False</option>
									<option value="true">True</option>
								</select>
							</div>
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-inline">
							<label class="layui-form-label">重新进入队列<a id="scheme_14" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('', '#scheme_14',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
								<select name="abanresumealo" >
									<option value="false">False</option>
									<option value="true">True</option>
								</select>
							</div>
						</div>
						<div class="layui-inline">
							<label class="layui-form-label">最大放弃时长<a id="scheme_15" href="javacript:void(0);"  onmouseenter="subtips=layer.tips('主叫方放弃排队后的秒数,用于来电再次呼入队列后是否进入上一次排队位置。如果在设置时间内恢复上一次排队位置，如果不再超过时间就不恢复。', '#scheme_15',{tips:[1,'#ff6700'],time: 30000});" onmouseleave="layer.close(subtips);" >
								<i class="layui-icon layui-icon-about" style="font-size: 16px;"></i>  
							</a>：</label>
							<div class="layui-input-inline">
				                <input type="number" min="0" name="disabanafter" placeholder="最大放弃时长" value="60" autocomplete="off" class="layui-input">
				            </div>
						</div>
					</div>
				</div>
			</div>
		</div>
        <div class="layui-form-button">
            <div class="layui-button-block">
                <button class="layui-btn" lay-submit lay-filter="formDemo">立即提交</button>
                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
            </div>
        </div>
    </form>
</div>
<script>
	layui.use('form', function(){
	  var form = layui.form;
	  form.render();
	  
	});
</script>